package com.lazyfish.superdir.controller;

import com.lazyfish.superdir.service.StudentPositiveService;
import com.lazyfish.util.ResultBuild;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;
@CrossOrigin
@Controller
public class StudentPositiveController {
    @Autowired
    private StudentPositiveService studentPositiveService;
    @RequestMapping("/getStudentPositive")
    @ResponseBody
    public ResultBuild getStudentPositive(String name, String _class){
        if(name.equals("") || _class.equals("")){
            return new ResultBuild(200,null);
        }
        return new ResultBuild(200,studentPositiveService.getStudentPositive(name,_class));
    }
}
